package com.mjw.zstu.controller;

import com.mjw.zstu.resultDto.JsonResult;
import com.mjw.zstu.service.EchartsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@CrossOrigin
@RestController
@RequestMapping("echart")
public class EchartsController {
    @Autowired
    EchartsService echartsService;
    @RequestMapping("product_ten")
    public JsonResult p_ten(){
       return echartsService.product_ten();
    };
    @RequestMapping("exhibition_ten")
    public JsonResult ex_ten(){
        return echartsService.exhibition_ten();
    }
    @RequestMapping("pie")
    public JsonResult pieEx(){
        return echartsService.pieEx();
    }
    @RequestMapping("companynum")
    public JsonResult companyNum(){
        return echartsService.Companycount();
    }
    @RequestMapping("usernum")
    public JsonResult usernum(){
        return echartsService.Usernum();
    }
    @RequestMapping("exnum")
    public JsonResult exnum(){
        return echartsService.Exnum();
    }
    @RequestMapping("todayex")
    public JsonResult todayex(){
        return echartsService.todayEx();
    }
    @RequestMapping("user")
        public JsonResult user(){
       return echartsService.registerUser();
    }
    @RequestMapping("order")
    public JsonResult order(){
        return echartsService.order();
    }
    

}
